package com.yuda.campsite.service.impl;

import java.util.List;

import com.yuda.campsite.service.ICampsiteWorkTeacherService;
import com.yuda.common.core.utils.DateUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.yuda.campsite.mapper.CampsiteWorkTeacherMapper;
import com.yuda.campsite.domain.CampsiteWorkTeacher;
import com.yuda.campsite.service.ICampsiteWorkTeacherService;

import javax.annotation.Resource;

/**
 * 【请填写功能名称】Service业务层处理
 *
 * @author wyn
 * @date 2021-12-06
 */
@Service
public class CampsiteWorkTeacherServiceImpl implements ICampsiteWorkTeacherService
{
    @Resource
    private CampsiteWorkTeacherMapper campsiteWorkTeacherMapper;

    /**
     * 查询【请填写功能名称】
     *
     * @param id 【请填写功能名称】ID
     * @return 【请填写功能名称】
     */
    @Override
    public CampsiteWorkTeacher selectCampsiteWorkTeacherById(Long id)
    {
        return campsiteWorkTeacherMapper.selectCampsiteWorkTeacherById(id);
    }

    /**
     * 查询【请填写功能名称】列表
     *
     * @param campsiteWorkTeacher 【请填写功能名称】
     * @return 【请填写功能名称】
     */
    @Override
    public List<CampsiteWorkTeacher> selectCampsiteWorkTeacherList(CampsiteWorkTeacher campsiteWorkTeacher)
    {
        return campsiteWorkTeacherMapper.selectCampsiteWorkTeacherList(campsiteWorkTeacher);
    }

    /**
     * 新增【请填写功能名称】
     *
     * @param campsiteWorkTeacher 【请填写功能名称】
     * @return 结果
     */
    @Override
    public int insertCampsiteWorkTeacher(CampsiteWorkTeacher campsiteWorkTeacher)
    {
        campsiteWorkTeacher.setCreateTime(DateUtils.getNowDate());
        return campsiteWorkTeacherMapper.insertCampsiteWorkTeacher(campsiteWorkTeacher);
    }

    /**
     * 修改【请填写功能名称】
     *
     * @param campsiteWorkTeacher 【请填写功能名称】
     * @return 结果
     */
    @Override
    public int updateCampsiteWorkTeacher(CampsiteWorkTeacher campsiteWorkTeacher)
    {
        campsiteWorkTeacher.setUpdateTime(DateUtils.getNowDate());
        return campsiteWorkTeacherMapper.updateCampsiteWorkTeacher(campsiteWorkTeacher);
    }

    /**
     * 批量删除【请填写功能名称】
     *
     * @param ids 需要删除的【请填写功能名称】ID
     * @return 结果
     */
    @Override
    public int deleteCampsiteWorkTeacherByIds(Long[] ids)
    {
        return campsiteWorkTeacherMapper.deleteCampsiteWorkTeacherByIds(ids);
    }

    /**
     * 删除【请填写功能名称】信息
     *
     * @param id 【请填写功能名称】ID
     * @return 结果
     */
    @Override
    public int deleteCampsiteWorkTeacherById(Long id)
    {
        return campsiteWorkTeacherMapper.deleteCampsiteWorkTeacherById(id);
    }

    @Override
    public Integer ZuoYeNum(String campId) {
        return campsiteWorkTeacherMapper.ZuoYeNum(campId);
    }

    @Override
    public int WorkLuoJi(String campId, Integer id) {
        return campsiteWorkTeacherMapper.WorkLuoJi(campId, id);
    }

    @Override
    public List<String> ChaXunZuoYe(Long campId) {
        return campsiteWorkTeacherMapper.ChaXunZuoYe(campId);
    }

    @Override
    public int XiuGaiZuoYeTiHao(Integer worknumber, String workname, Long campId) {
        return campsiteWorkTeacherMapper.XiuGaiZuoYeTiHao(worknumber, workname, campId);
    }

    @Override
    public String DanGeZuoYe(Long id) {
        return campsiteWorkTeacherMapper.DanGeZuoYe(id);
    }

    @Override
    public String IsStudentTiJiao(Long id) {
        return campsiteWorkTeacherMapper.IsStudentTiJiao(id);
    }

    @Override
    public String getStuEnclosUrl(String studentId, String campId) {

        return campsiteWorkTeacherMapper.getStuEnclosUrl( studentId,  campId) ;
    }

    @Override
    public String SelectByIdUuid(String studentId) {
        return campsiteWorkTeacherMapper.SelectByIdUuid(studentId);
    }


}
